package request

import "blog-server/app/models"

type ShareModel struct {
	PageId    uint        `json:"pageId" gorm:"primaryKey"`
	PageName  string      `json:"pageName"`
	Remark    string      `json:"remark" gorm:"not null;comment:副标题"`
	CoverUrl  string      `json:"coverUrl" gorm:"not null;comment:封面"`
	Status    int         `json:"status" gorm:"not null default: 0; comment:状态 0-下架中 1-上架中"`
	Spacial   string      `json:"spacial" gorm:"not null;comment: 专题"`
	ArtType   int         `json:"artType" gorm:"not null; comment: 1-音乐 2-技术 3-文化"`
	Tags      models.Strs `json:"tags" gorm:"type:longtext; not null; comment: 标签"`
	Author    string      `json:"author" gorm:"not null; comment:作者"`
	ContentId uint        `json:"contentId" gorm:"primaryKey"`
	Content   string      `json:"content" gorm:"not null;comment: md内容"`
	VideoUrl  string      `json:"videoUrl" gorm:"not null;comment:视频地址"`
}
type ShareList struct {
	PageName string `json:"pageName" form:"pageName"`
	ArtType  int    `json:"artType" form:"artType"`
	PageNum  int    `form:"pageNum" json:"pageNum"`
	PageSize int    `form:"pageSize" json:"pageSize"`
}

type ShareDetail struct {
	ArtType   int  `json:"artType" from:"artType"`
	ContentId uint `json:"contentId" from:"contentId"`
}

type DelShare struct {
	ArtType   int  `json:"artType" form:"artType"`
	PageId    uint `json:"pageId" form:"pageId"`
	ContentId uint `json:"contentId" form:"contentId"`
}

// 上下架
type ShareSelf struct {
	ArtType int  `json:"artType" form:"artType"`
	PageId  uint `json:"pageId" form:"pageId"`
	Status  int  `json:"status" form:"status"`
}
